package com.sinoglobal.ningxia.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by XINDZ on 2017/2/17.
 * 功能:视频栏目(元微视听的adapter)
 */

public class NewVideoPagerAdapter extends FragmentPagerAdapter {
    private List<Fragment> fragmentList = new ArrayList<>();
    private List<String> titleNameList = new ArrayList<>();

    public void setFragmentList(List<Fragment> fragmentList, List<String> titleNameList) {
        this.fragmentList = fragmentList;
        this.titleNameList = titleNameList;
    }

    public NewVideoPagerAdapter(FragmentManager fm) {
        super(fm);
    }

    @Override
    public Fragment getItem(int position) {
        return fragmentList.get(position);
    }

    @Override
    public int getCount() {
        return fragmentList.size();
    }



}
